{{- if .Values.cloudProviderYandex.internal.providerDiscoveryData.monitoringAPIKey }}
apiVersion: v1
kind: Secret
metadata:
  name: cloud-metrics-exporter-app-creds
  namespace: d8-cloud-provider-yandex
  {{- include "helm_lib_module_labels" (list . (dict "app" "cloud-metrics-exporter")) | nindent 2 }}
type: Opaque
data:
  api-key: {{ .Values.cloudProviderYandex.internal.providerDiscoveryData.monitoringAPIKey | b64enc | quote }}
  folder-id: {{ .Values.cloudProviderYandex.internal.providerClusterConfiguration.provider.folderID | b64enc | quote }}
{{- end }}
